﻿<UserControl x:Class="SurfaceApplication3.MetaDataEntry"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:s="http://schemas.microsoft.com/surface/2008"
             mc:Ignorable="d" Background="#B0CAB8"
             Height="125" Width="930">

    <UserControl.Resources>
        <Style TargetType="s:SurfaceButton" x:Key="browse">
            <Setter Property="FontSize" Value="16"/>
            <Setter Property="Foreground" Value="White"/>
            <Setter Property="Background" Value="#227174"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="s:SurfaceButton">
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsPressed" Value="True">
                                <Setter Property="Background" >
                                    <Setter.Value>
                                        <LinearGradientBrush StartPoint="0,0" EndPoint="0,1" >
                                            <GradientStop Color="#FF90DDFF" Offset="0.35"/>
                                            <GradientStop Color="LightBlue" Offset="0.95"/>
                                            <GradientStop Color="#FF81DDFF" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Setter.Value>
                                </Setter>
                            </Trigger>

                            
                        </ControlTemplate.Triggers>
                        <Border CornerRadius="7" Margin="0" Background="{TemplateBinding Background}" BorderBrush="#227174" BorderThickness="2">
                            <ContentPresenter 
                                HorizontalAlignment="Center"
                                VerticalAlignment="Center"
                                >
                            </ContentPresenter>
                        </Border>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>

        <Style TargetType="s:SurfaceButton" x:Key="remove">
            <Setter Property="FontSize" Value="16"/>
            <Setter Property="Foreground" Value="White"/>
            <Setter Property="Background" Value="#227174"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="s:SurfaceButton">
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsPressed" Value="True">
                                <Setter Property="Background" >
                                    <Setter.Value>
                                        <LinearGradientBrush StartPoint="0,0" EndPoint="0,1" >
                                            <GradientStop Color="#FF90DDFF" Offset="0.35"/>
                                            <GradientStop Color="LightBlue" Offset="0.95"/>
                                            <GradientStop Color="#FF81DDFF" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Setter.Value>
                                </Setter>
                            </Trigger>
                        </ControlTemplate.Triggers>
                        <Border CornerRadius="7" Margin="0" Background="{TemplateBinding Background}" BorderBrush="#227174" BorderThickness="2">
                            
                            <ContentPresenter 
                                HorizontalAlignment="Center"
                                VerticalAlignment="Center"
                                >
                            </ContentPresenter>
                        </Border>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
    </UserControl.Resources>

    <Grid x:Name="LayoutRoot" >
        <Canvas >
            <Rectangle x:Name="middle_background" Fill="White" Height="50" Width="916" Canvas.Top="25" Canvas.Left="8"/>
            <Canvas Name="imageCanvas" Height="108" Width="158" Canvas.Top="8" Canvas.Left="11">
                <Rectangle x:Name="imageRec" Fill="#B8DAD2" Height="108" Canvas.Left="0" Stroke="#227174" Width="158" StrokeThickness="4" Canvas.Top="0" />
                <Image x:Name="image1" Height="100" Width="150" Canvas.Left="4" Canvas.Top="4" ImageFailed="image1_ImageFailed" />
            </Canvas>
            <s:SurfaceButton Style="{StaticResource browse}"  Content="Browse" Canvas.Left="180" Canvas.Top="82" Width="76" Height="30" Margin="1" BorderBrush="#227174" BorderThickness="10"  Click="Browse_Click" MinHeight="0" MinWidth="0" />
            <s:SurfaceButton Style="{StaticResource browse}"  Content="From Web" Canvas.Left="260" Canvas.Top="82" Width="96" Height="30" Margin="1" BorderBrush="#227174" BorderThickness="10"  Click="Web_Click" MinHeight="0" MinWidth="0" />
                <Label Content="Name:" Canvas.Left="251" Canvas.Top="35" Width="76" Height="36.5" Foreground="Black" />
                 <Label Content="Description:" Canvas.Left="555" Canvas.Top="33" Foreground="Black"/>
            <s:SurfaceTextBox x:Name="tags" Height="50" Width="253" BorderBrush="#227174" BorderThickness="2" Canvas.Left="662" Background="{x:Null}" Canvas.Top="24" Foreground="Black" IsReadOnly="True" Visibility="Hidden"/>
            <s:SurfaceTextBox x:Name="summary" Height="50" Width="253" BorderBrush="#227174" BorderThickness="2" Canvas.Left="662" Background="{x:Null}" Canvas.Top="24" Foreground="Black" VerticalScrollBarVisibility="Auto" FontSize="15" TextWrapping="Wrap" MouseDoubleClick="summary_MouseDoubleClick" />
            
            <s:SurfaceButton Style="{StaticResource remove}" x:Name="remove" Height="30" Width="86" Content="Remove" MinHeight="0" Canvas.Left="830" Canvas.Top="83" Click="remove_Click" MinWidth="0" />
            <s:SurfaceTextBox x:Name="name_tag" Height="30" Width="170" BorderBrush="#227174" BorderThickness="2" Canvas.Left="315" Canvas.Top="33" Background="{x:Null}" Foreground="Black" FontSize="15" MinHeight="0" MinWidth="0" />
            <s:SurfaceTextBox x:Name="title_tag" Height="30" Width="240" BorderBrush="#227174" BorderThickness="2" Canvas.Left="362" Canvas.Top="83" Background="{x:Null}" Foreground="Black" FontSize="15" IsReadOnly="True" MinHeight="0" MinWidth="0" Visibility="Hidden"/>
                
        </Canvas>
        </Grid>
   
</UserControl>
